<!--<div id="main-banner"><img src="<?php echo base_url(); ?>images/accomodation_main.jpg" height="320" width="595"></div>-->
    <div id="breadcrumbs"><?php echo $breadcrumb; ?></div>

<div>      
    <div>
    <?php
    //print_r($customlinks);
    $tmpkey=0;
    $exit=false;
    //echo "<br>count:".count($customlinks);
    foreach ($customlinks as $key => $val)  :        
        //echo "<br>key: ".$key;
        if($exit){
            break;
        }        
    ?>
        <?php for ($i = 0; $i < 3; $i++) : 
        $heading='';
        //echo "tmpkey: ".$tmpkey;
        if ($tmpkey>=count($customlinks)){
            $exit=true;
            break;
        }
            ?>
        <div class="ite_col<?php echo $i+1?>">
        <div><img src="<?php echo base_url(); ?>images/uploads/thumb/thumb_<?php echo $customlinks[$tmpkey]['image']; ?>" alt="" width="174" height="133" /></div>
        <div>
        <p class="it_heading"><?php echo $customlinks[$tmpkey]['title']; ?></p>
        </div>
        <?php 
         /*$str=strlen($customlinks[$tmpkey]['desc'])>50?substr($customlinks[$tmpkey]['desc'], 0, 50):$customlinks[$tmpkey]['desc'];
         $pos=strpos($str, ' ', 40);
         if($pos!==false){
             $heading=substr($str, 0, $pos);
         }*/
        ?>
        <div><strong><?php //echo $heading; ?> <?php echo $customlinks[$tmpkey]['title']; ?></strong></div>
        <div>
          <p><?php echo strlen($customlinks[$tmpkey]['desc'])>150?substr($customlinks[$tmpkey]['desc'], 0, 150)."...":$customlinks[$tmpkey]['desc']; ?></p>
          <?php if ($customlinks[$tmpkey]['cost']>0):?>
          <p class="it_price"> <?php echo $customlinks[$tmpkey]['cost']; ?> EUR</p>
          <?php endif; ?>
          <p><a href="<?php echo base_url()?>/pages/itenerydetails/<?php echo $customlinks[$tmpkey]['customlinks_id']?>"><img src="<?php echo base_url()?>images/readmore.jpg" width="78" height="27" /></a></p>
        </div>
        </div>
        <?php 
        //$key=$key+i;
        /*if (i==2){
            break;
        }*/
        $tmpkey+=1;
        endfor;         
        //echo "<br>key: ".$key;
        ?>
    <?php endforeach; ?>
    </div>    
</div>
    <div id="pagecontroller"><?php echo $pagination;?></div>
<div class="clear"></div>